<div style="padding:10px 20px 20px 20px;margin:0px 0;">
	<div style="float:left;margin:10px 0px 10px 0;width:100%;">
	<form th:id="${formID}" action="#"  method="post" enctype="multipart/form-data">
		<div style="margin:0 20px;float:left;">
		<input  id="orgLname" class="easyui-textbox wd50" type="text" 
					th:label="#{orgInfo.orgLname}+'  :'" label="机构简称"  name="orgLname"   />
			<br style="clear:both;">
		</div>
		<div style="margin:0 20px;float:left;">
		<input  id="orgHname" class="easyui-textbox wd50" type="text" 
					th:label="#{orgInfo.orgHname}+'  :'" label="机构全名"  name="orgHname"   />
			<br style="clear:both;">
		</div>
		<div style="margin:0 20px;float:left;">
		<input  id="orgCode" class="easyui-textbox wd50" type="text" 
					th:label="#{orgInfo.orgCode}+'  :'" label="机构编号"  name="orgCode"   />
			<br style="clear:both;">
		</div>
		<div style="margin:0 20px;float:left;">
		<input  id="orgUser" class="easyui-textbox wd50" type="text" 
					th:label="#{orgInfo.orgUser}+'  :'" label="机构联系人"  name="orgUser"   />
			<br style="clear:both;">
		</div>
		<div style="margin:0 20px;float:left;">
		<input  id="orgTel" class="easyui-textbox wd50" type="text" 
					th:label="#{orgInfo.orgTel}+'  :'" label="机构联系电话"  name="orgTel"   />
			<br style="clear:both;">
		</div>
		<div style="margin:0 20px;float:left;">
		<input  id="orgEmail" class="easyui-textbox wd50" type="text" 
					th:label="#{orgInfo.orgEmail}+'  :'" label="机构邮箱"  name="orgEmail"   />
			<br style="clear:both;">
		</div>
		<div style="margin:0 20px;float:left;">
		<input  id="orgAdda" class="easyui-textbox wd50" type="text" 
					th:label="#{orgInfo.orgAdda}+'  :'" label="机构地址（省）"  name="orgAdda"   />
			<br style="clear:both;">
		</div>
		<div style="margin:0 20px;float:left;">
		<input  id="orgAddb" class="easyui-textbox wd50" type="text" 
					th:label="#{orgInfo.orgAddb}+'  :'" label="机构地址（市）"  name="orgAddb"   />
			<br style="clear:both;">
		</div>
		<div style="margin:0 20px;float:left;">
		<input  id="orgAddc" class="easyui-textbox wd50" type="text" 
					th:label="#{orgInfo.orgAddc}+'  :'" label="机构地址（地区）"  name="orgAddc"   />
			<br style="clear:both;">
		</div>
		<div style="margin:0 20px;float:left;">
		<input  id="orgAddd" class="easyui-textbox wd50" type="text" 
					th:label="#{orgInfo.orgAddd}+'  :'" label="机构地址（乡镇）"  name="orgAddd"   />
			<br style="clear:both;">
		</div>
		<div style="margin:0 20px;float:left;">
		<input  id="orgAdde" class="easyui-textbox wd50" type="text" 
					th:label="#{orgInfo.orgAdde}+'  :'" label="机构地址（村）"  name="orgAdde"   />
			<br style="clear:both;">
		</div>
		<div style="margin:0 20px;float:left;">
		<input  id="orgLon" class="easyui-textbox wd50" type="text" 
					th:label="#{orgInfo.orgLon}+'  :'" label="经度"  name="orgLon"   />
			<br style="clear:both;">
		</div>
		<div style="margin:0 20px;float:left;">
		<input  id="orgLat" class="easyui-textbox wd50" type="text" 
					th:label="#{orgInfo.orgLat}+'  :'" label="纬度"  name="orgLat"   />
			<br style="clear:both;">
		</div>
		<div style="margin:0 20px;float:left;">
		<input  id="orgPcode" class="easyui-textbox wd50" type="text" 
					th:label="#{orgInfo.orgPcode}+'  :'" label="机构邮编"  name="orgPcode"   />
			<br style="clear:both;">
		</div>
		<div style="margin:0 20px;float:left;">
		<input  id="orgSort" class="easyui-textbox wd50" type="text" 
					th:label="#{orgInfo.orgSort}+'  :'" label="机构排序"  name="orgSort"   />
			<br style="clear:both;">
		</div>
		<div style="margin:0 20px;float:left;clear:right;">
			<a th:href="'javascript:search(\''+${formID}+'\')'" class="easyui-linkbutton" iconCls="icon-search">查询</a>
		</div>
	</form>
	</div>
	<div style="float:left;margin-bottom:1px;width:100%;">
	<div style="float:left;">
		<a th:href="'javascript:batchdel(\''+${formID}+'\')'" class="easyui-linkbutton">批量删除</a>
		<input th:id="'show'+${formID}" type="hidden" th:value="@{org/orgInfo/queryForOrgInfoDetail}" />
		<input th:id="'edit'+${formID}" type="hidden" th:value="@{org/orgInfo/addOrgInfo}" /> 
		<input th:id="'del'+${formID}" type="hidden" th:value="@{org/orgInfo/deleteByOrgInfoId}" />
		<input th:id="'mid'+${formID}" type="hidden" value="orgId" />
		<input th:id="'batchdel'+${formID}" type="hidden" th:value="@{org/orgInfo/deleteByOrgInfoIdBatch}" /> 
	</div>
	<div style="margin-left:10px;float:right;">
		<a th:id="'imp'+${formID}"  href="#" class="easyui-linkbutton" iconCls="" th:onclick="'javascript:importExcelMode(\''+${formID}+'\')'">导入</a>&nbsp;
		<a href="#" class="easyui-linkbutton" iconCls="" th:onclick="'javascript:downloadExcelMode(\''+@{/UploadFiles/Fj/AqglHseAqjc.xlsx}+'\')'">下载模板</a> &nbsp;
		<a href="#" class="easyui-linkbutton" iconCls="" onclick="exportExcelMode(\''+${formID}+'\')'">导出</a>
		
	</div>
	<form th:id="'impForm'+${formID}" action="#"  method="post" enctype="multipart/form-data"> 
		<div style="margin-left:10px;float:right;">
			<input class="easyui-filebox"
			data-options="label:'导入文件:',prompt:'请选择一个Excel文件',buttonText:'选择文件',
			accept:'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet, application/vnd.ms-excel'"
			th:id="'file'+${formID}"  name="file" style="width:300px;">
		</div>
	</form>
	</div>

	<table  th:id="'datagrid'+${formID}" class="easyui-datagrid" title="组织机构信息表" style="width:100%;"
			data-options="url:'org/orgInfo/queryForOrgInfoListDG',
			method:'get',rownumbers:true, nowrap: false,singleSelect:false,autoRowHeight: true,
			fitColumns: true,striped:true,idField:'menuInfoId',loadMsg: '正在加载...',pagination:true,pageSize:10">
		<thead data-options="frozen:true">
			<tr>
				<th data-options="field:'ck',checkbox:true" ></th>
				<th data-options="field:'orgLname',resizable:true,halign:'center'" width="15%"><span th:text="#{orgInfo.orgLname}">机构简称</span></th>
				<th data-options="field:'orgHname',resizable:true,halign:'center'" width="15%"><span th:text="#{orgInfo.orgHname}">机构全名</span></th>
				<th data-options="field:'orgCode',resizable:true,halign:'center'" width="15%"><span th:text="#{orgInfo.orgCode}">机构编号</span></th>
				<th data-options="field:'orgUser',resizable:true,halign:'center'" width="15%"><span th:text="#{orgInfo.orgUser}">机构联系人</span></th>
				<th data-options="field:'orgTel',resizable:true,halign:'center'" width="15%"><span th:text="#{orgInfo.orgTel}">机构联系电话</span></th>
				<th data-options="field:'orgEmail',resizable:true,halign:'center'" width="15%"><span th:text="#{orgInfo.orgEmail}">机构邮箱</span></th>
				<th data-options="field:'orgAdda',resizable:true,halign:'center'" width="15%"><span th:text="#{orgInfo.orgAdda}">机构地址（省）</span></th>
				<th data-options="field:'orgAddb',resizable:true,halign:'center'" width="15%"><span th:text="#{orgInfo.orgAddb}">机构地址（市）</span></th>
				<th data-options="field:'orgAddc',resizable:true,halign:'center'" width="15%"><span th:text="#{orgInfo.orgAddc}">机构地址（地区）</span></th>
				<th data-options="field:'orgAddd',resizable:true,halign:'center'" width="15%"><span th:text="#{orgInfo.orgAddd}">机构地址（乡镇）</span></th>
				<th data-options="field:'orgAdde',resizable:true,halign:'center'" width="15%"><span th:text="#{orgInfo.orgAdde}">机构地址（村）</span></th>
				<th data-options="field:'orgLon',resizable:true,halign:'center'" width="15%"><span th:text="#{orgInfo.orgLon}">经度</span></th>
				<th data-options="field:'orgLat',resizable:true,halign:'center'" width="15%"><span th:text="#{orgInfo.orgLat}">纬度</span></th>
				<th data-options="field:'orgPcode',resizable:true,halign:'center'" width="15%"><span th:text="#{orgInfo.orgPcode}">机构邮编</span></th>
				<th data-options="field:'orgSort',resizable:true,halign:'center'" width="15%"><span th:text="#{orgInfo.orgSort}">机构排序</span></th>
			</tr>
		</thead>
	</table> 
</div> 
<script type="text/javascript">
	//操作
	function onOptOrgInfo(value,row,index){ 
		var s =  '<a class="Edit_Button" href="javascript:showDetail(\''+value+'\',\'展示《'+row.orgLname+'》详情信息\',\'[[${formID}]] \')">详细</a>'+
			'&nbsp;'+
			'<a class="Edit_Button" href="javascript:edit(\''+value+'\',\'编辑《'+row.orgLname+'》信息\',\'[[${formID}]] \')">编辑</a>'+
			'&nbsp;'+
			'<a class="Delete_Button" href="javascript:remove(\''+value+'\',\'[[${formID}]]\')" >删除</a>' ;
		return s;
	}
	
	//导入 
	function importExcelMode(formID){
		var file = $('#file'+formID).filebox('getValue');
		if(file==""){ 
			 $.messager.alert({ width: 350, title:'温馨提示', msg:'导入文件不能为空!', icon:'info'});
			return; 
		}
		 $('#imp'+formID).linkbutton('disable');
		$("#impForm"+formID).ajaxSubmit({
			type: "post",
			dataType: "json",
			url: '[[@{org/orgInfo/importGenerateInfo }]]', 
			success:function(data){ 
				$('#imp'+formID).linkbutton('enable'); 
				console.log(data)
				if (data.code == 200) {
					dataReload(formID); 
					$.messager.alert({width: 280,title: '操作成功',msg: data.msg, icon:'info'});
				}else{
					$.messager.alert({ width: 280, title:'数据提交异常', msg:data.msg});
				}
			},error: function (data) {
				$('#imp'+formID).linkbutton('enable'); 
				$.messager.alert('消息提醒','上传失败，数据异常！');
			}
		});
	}
			
			
		
	

</script>



				<th width="15%"> 机构简称</th>
				<th width="15%"> 机构全名</th>
				<th width="15%"> 机构编号</th>
				<th width="15%"> 机构联系人</th>
				<th width="15%"> 机构联系电话</th>
				<th width="15%"> 机构邮箱</th>
				<th width="15%"> 机构地址（省）</th>
				<th width="15%"> 机构地址（市）</th>
				<th width="15%"> 机构地址（地区）</th>
				<th width="15%"> 机构地址（乡镇）</th>
				<th width="15%"> 机构地址（村）</th>
				<th width="15%"> 经度</th>
				<th width="15%"> 纬度</th>
				<th width="15%"> 机构邮编</th>
				<th width="15%"> 机构排序</th>
				<td width="15%"><span th:text="#{orgInfo.orgLname}"></span></td>
				<td width="15%"><span th:text="#{orgInfo.orgHname}"></span></td>
				<td width="15%"><span th:text="#{orgInfo.orgCode}"></span></td>
				<td width="15%"><span th:text="#{orgInfo.orgUser}"></span></td>
				<td width="15%"><span th:text="#{orgInfo.orgTel}"></span></td>
				<td width="15%"><span th:text="#{orgInfo.orgEmail}"></span></td>
				<td width="15%"><span th:text="#{orgInfo.orgAdda}"></span></td>
				<td width="15%"><span th:text="#{orgInfo.orgAddb}"></span></td>
				<td width="15%"><span th:text="#{orgInfo.orgAddc}"></span></td>
				<td width="15%"><span th:text="#{orgInfo.orgAddd}"></span></td>
				<td width="15%"><span th:text="#{orgInfo.orgAdde}"></span></td>
				<td width="15%"><span th:text="#{orgInfo.orgLon}"></span></td>
				<td width="15%"><span th:text="#{orgInfo.orgLat}"></span></td>
				<td width="15%"><span th:text="#{orgInfo.orgPcode}"></span></td>
				<td width="15%"><span th:text="#{orgInfo.orgSort}"></span></td>
